package io.geekidea.boot.notice.dto;

import io.geekidea.boot.common.GroupValidator;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.io.Serializable;

/**
 * 新增、修改公告表单参数
 */
@Data
@Schema(description = "新增、修改公告表单参数")
public class NoticeDto implements Serializable {
    private static final long serialVersionUID = 1L;

    @Schema(description = "公告ID")
    @NotNull(groups = GroupValidator.Update.class,message = "公告编号不能为空")
    private Integer id;

    @Schema(description = "公告标题")
    @NotBlank(message = "公告标题不能为空")
    private String name;


    @Schema(description = "公告详情")
    @NotBlank(message = "公告详情不能为空")
    private String content;

    @Schema(description = "公告状态")
    @NotBlank(message = "战区公告or总部公告")
    private String type;

}


